Conversation
franchizi
reviewed
Mar 31, 2021
| Join the OrderDetails and Products tables, to show a report where the columns are OrderID, ProductName, and Quantity. | ||
| Paste the SQL statement you used below. | ||
|
|
||
| SELECT od.OrderID, prod.ProductName, od.Quantity FROM OrderDetails od INNER JOIN Products prod ON od.ProductID = prod.ProductID; |
|
|
||
| SELECT (e.FirstName || " " || e.LastName) AS EmployeeName, od.ProductID, od.Quantity FROM Orders o | ||
| INNER JOIN OrderDetails od ON o.OrderID = od.OrderID | ||
| INNER JOIN Employees e ON o.EmployeeID = e.EmployeeID; |
| age = gets.chomp | ||
| age = age.to_i | ||
| seconds = years_to_days(age) * 24 * 60 * 60 | ||
| puts "You're #{seconds} seconds old." |
There was a problem hiding this comment.
This is pretty well done. John mentioned that he mistakenly asked you all to worry about leap years too. So you came up with a solution to that when you shouldn't have needed too.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Student Ming King.
Submit week2 assignment.